﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Security.Principal;
using XCommunity.Documents;
using XCommunity.Frames;
using XCommunity.Caching;
using XCommunity.Members;

namespace XCommunity
{

  /// <summary>
  /// XCommunity的基础上下文
  /// </summary>
  /// <remarks>
  /// 任何XCommunity承载平台必须实现和扩展XCommunity基础上下文
  /// 此上下文中包含了XCommunity所有的基础服务，CacheService、DocumentService和FrameService。并且提供当前登录的账户。
  /// XCommunity基础上下文中并不包含任何社区系统的信息，同样用户和视图服务也不包含在基础上下文中。
  /// </remarks>
  public interface ICommunityContext
  {

    IIdentity CurrentAccount
    {
      get;
    }

    MemberService MemberService
    {
      get;
    }


    CacheService CacheService
    {
      get;
    }

    DocumentService DocumentService
    {
      get;
    }
    
    FrameService FrameService
    {
      get;
    }

    ICommunitySystem GetCommunitySystem( Guid communitySystemId );

  }
}
